﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace array
{
    class Program
    {
        static int[] ReverseArray2(int[] array)
        {
            for (int i = 0; i < array.Length / 2; i++)
            {
                int temp = array[array.Length - 1];
                array[array.Length -1 ] = array[i];
                array[i] = temp;
            }
            
            return array;
        }
        //static int[] ReverseArray1 (int [] array)
        //{

        //    int [] result = new int [array.Length];
        //    int position = 0;
        //    for (int i = array.Length - 1; i >=0; i--)
        //    {
        //        result[position] = array[i];

        //    }
        //    return result;
        //}
        //static int CalculateMax(int[] array)
        //{
        //    int res = Int32.MinValue;
        //    for (int i = 0; i < array.Length; i++)
        //    {
        //        if (array[i] > res)
        //            res = array[i];
        //    }
        //    return res;
        //}
        //static int CalculateMin (int [] array)
        //{
        //    int min = 0;
        //    for (int i = 0; i < array.Length; i++)
        //    {
                
        //    }
        //    return min;
        //}
        //static int CalculateArraySum (int [] array)
        //{
        //    int sum = 0;
        //    for (int i = 0; i < array.Length; i++)
        //    {
        //        sum = sum + array[i];
        //    }
        //    return sum;
        //}
        static void Main(string[] args)
        {
            Console.WriteLine("enter n");
            int n = Convert.ToInt32(Console.ReadLine());
            int [] storage = new int [n];

            for (int i = 0; i < n; i++)
            {
                Console.WriteLine("enter {0} number", i + 1);
                int temp = Convert.ToInt32(Console.ReadLine());
                storage[i] = temp;
            }

           // int sum = CalculateArraySum(storage);
            //int minvalue = CalculateMin(storage);
            //int maxvalue = CalculateMax(storage);
            //int [] reversearr = ReverseArray1(storage);

            Console.ReadKey();

        }
    }
}
